https://leetcode-cn.com/problems/roman-to-integer/submissions/
class Solution:
def romanToInt(self, s: str) -> int:
s_ = ['M','CM','D','CD','C','XC','L','XL','X','IX','V','IV','I']
v_ = [1000,900,500,400,100,90,50,40,10,9,5,4,1]
ret = 0
while s != '':
for i in s_:
if s[0:len(i)] == i:
ret += v_[s_.index(i)]
s = s[len(i):]
break
return ret